import { defineStore } from "pinia";
export default defineStore("try", {
  state() {
    return {
      members: [],
      seats: [],
      tasks: [],
      memberTags: [],
      selectedGroupName: "Group",
      selectedMembers: [],
      timeRange: {
        startDate: new Date(),
        endDate: new Date(),
        startTime: new Date(),
        endTime: new Date(),
      },
    };
  },
  getters: {
    membersInSelectedGroup: function () {
      return this.members.filter(
        (member) => member.groupName == this.selectedGroupName
      );
    },
  },
  actions: {
    increament() {
      this.counter++;
    },
  },
});
